<?php

namespace app\controllers\h5\services;

use app\services\base\BaseService;
use app\models\product\Product as Model;

/**
 * Class Product
 * @package app\controllers\h5\services
 */
class Product
{
    use BaseService;

    /**
     * check group area
     *
     * @param array $area
     * @return bool
     */
    public static function checkGroupArea($area = [])
    {
        if (is_array($area) && count($area) > 0) {
            foreach ($area as $item) {
                if ($item['area_id'] == Model::$areaMap['GROUP']) {
                    return true;
                }
            }

            return false;
        }
    }
}